package com.xinsoft.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.xinsoft.entity.dto.ScmProduceConsumingParam;
import com.xinsoft.entity.po.ScmProduceConsuming;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xinsoft.entity.vo.ScmProduceConsumingPageVo;
import com.xinsoft.entity.vo.ScmProduceConsumingVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author ZYM
* @description 针对表【scm_produce_consuming(生产领用)】的数据库操作Mapper
* @createDate 2023-08-14 11:30:37
* @Entity com.xinsoft.entity.po.ScmProduceConsuming
*/
public interface ScmProduceConsumingMapper extends BaseMapper<ScmProduceConsuming> {

    IPage<ScmProduceConsumingPageVo> findListByParam(Page<ScmProduceConsumingPageVo> page,@Param("param") ScmProduceConsumingParam param);
    List<ScmProduceConsumingPageVo> findListByParam(@Param("param") ScmProduceConsumingParam param);

    ScmProduceConsumingVo getById(Integer id);

    /**
     * 获取被生产退料引用的数量
     * @param id 采购入库id
     * @return int
     */
    int getProduceConsumingCiteCount(Integer id);
}




